-
Notifications
You must be signed in to change notification settings - Fork 775
test(amazonq): add more tests for /transform #6183
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
| authType = 'awsId' | ||
| } | ||
| return authType | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This above function was previously in transformApiHandler.ts, just moving it here so it's in a shared utils file
| assert.strictEqual(usesHttpsAndExpiresAfter60Seconds, true) | ||
| }) | ||
|
|
||
| it('WHEN zipCode THEN ZIP contains all expected files and no unexpected files', async function () { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Moved this test to the file above with the other zipCode tests
| @@ -35,10 +34,6 @@ describe('transformByQ', async function () { | |||
| await fs.writeFile(tempFilePath, 'sample content for the test file') | |||
| transformByQState.setProjectPath(tempDir) | |||
| const zipCodeResult = await zipCode({ | |||
| dependenciesFolder: { | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not used for these tests
packages/core/src/testE2E/amazonQTransform/transformByQ.test.ts
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How often will these tests be run & do they have to be manually triggered?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/runIntegrationTests to trigger them
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
They are also run automatically after merging.
| export { default as MessengerUtils } from './chat/controller/messenger/messengerUtils' | ||
| export { GumbyController } from './chat/controller/controller' | ||
| export { TabsStorage } from '../amazonq/webview/ui/storages/tabsStorage' | ||
| export * as startTransformByQ from '../../src/codewhisperer/commands/startTransformByQ' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm unable to run the tests in packages/amazonq/test/e2e/amazonq/transformByQ.test.ts by importing these things from the core module directly where they're defined, as I get an import error when doing that. So instead I have to export them here and then (in the test file, line 11) import them from here.
|
/runIntegrationTests |
|
/runIntegrationTests |
|
/runIntegrationTests |
|
/runIntegrationTests |
|
/runIntegrationTests |
|
/runIntegrationTests |
|
/runIntegrationTests |

Problem
/transformcould benefit from more test coverage.Solution
Add tests.
feature/xbranches will not be squash-merged at release time.License: I confirm that my contribution is made under the terms of the Apache 2.0 license.